//
//  VedioViewController.swift
//  TQMedia
//
//  Created by XieLB on 2018/9/28.
//  Copyright © 2018年 XieLB. All rights reserved.
//

import UIKit

class VedioViewController: UIViewController {

    override func viewWillDisappear(_ animated: Bool) {
        super.viewWillDisappear(animated)
        
        CTMediator.sharedInstance()?.tq_stopVedio()
    }
    
    override func viewDidLoad() {
        super.viewDidLoad()

        let fileName = "http://statics.aichezaixian.com/351609080199717_1_2018_08_10_10_31_43".md5 + ".mp4"
        let fileURL = kVideoDireURL.appendingPathComponent(fileName)
        let frame = CGRect.init(x: 0, y: 0, width: UIScreen.main.bounds.size.width, height: UIScreen.main.bounds.size.height)
        CTMediator.sharedInstance()?.tq_playVedio(filePath: fileURL, frame:frame, closer: { [weak self] (view) in
            self?.view.addSubview(view)
        })
    }

    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
        // Dispose of any resources that can be recreated.
    }
}

